package cloudPayAdmin.admin.dbapp.repo.traffic;

import cloudPayAdmin.admin.dbapp.entity.traffic.TTreeMessage;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

import java.util.List;

public interface TreeMessageRepo extends JpaRepository<TTreeMessage, Long>, JpaSpecificationExecutor<TTreeMessage> {

    List<TTreeMessage> findByDetectorIdAndEnable(Long detectorId, Boolean enable);

    List<TTreeMessage> findByDetectorIdAndEnableAndStartTimeBetween(Long detectorId, Boolean enable, String startTimeBegin, String startTimeEnd);

}
